<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>二维码生成工具</title>
    <link rel="stylesheet" href="../css/style.css">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
    <script src="../js/lib/qrcode.min.js"></script>
</head>
<body>
    <div class="container">
        <div class="header">
            <a href="index.html" class="back-button">
                <i class="fas fa-arrow-left"></i>
            </a>
            <h2>二维码生成工具</h2>
        </div>

        <div class="input-section">
            <textarea id="content" placeholder="请输入要生成二维码的内容..."></textarea>
        </div>

        <div class="options-section">
            <div class="option-group">
                <label>二维码大小:</label>
                <input type="number" id="size" value="200" min="100" max="1000">
            </div>
            <div class="option-group">
                <label>容错级别:</label>
                <select id="errorLevel">
                    <option value="L">低 (7%)</option>
                    <option value="M">中 (15%)</option>
                    <option value="Q">较高 (25%)</option>
                    <option value="H">高 (30%)</option>
                </select>
            </div>
        </div>

        <div class="button-group">
            <button onclick="generateQR()">生成二维码</button>
            <button onclick="downloadQR()">下载二维码</button>
        </div>

        <div id="qrcode"></div>
        <div id="toast" class="toast">操作成功</div>
    </div>
    <script src="../js/qrcode.js"></script>
</body>
</html> 